
#include "zadesk.h"
#include "zAdAChar.h"
#include "zacStatusBar.h"
#include "ucore_rxmfcapi.h"

#ifndef UD_RXMFCAPI_H
#define UD_RXMFCAPI_H 1
#pragma pack (push, 8)

#ifndef WM_UCAD_KEEPFOCUS
#define WM_UCAD_KEEPFOCUS  (WM_USER+0x6D01)
#endif

class UcDbDatabase;
class UcApStatusBar;
class CDialogBar;

#ifdef _ZSOFT_WINDOWS_
CWinApp* ucedGetUcadWinApp();

CDocument* ucedGetUcadDoc();

CView* ucedGetUcadDwgView();

CMDIFrameWnd* ucedGetUcadFrame();

CWnd* ucedGetUcadDockCmdLine();

CWnd* ucedGetUcadTextCmdLine();
#endif

HINSTANCE ucedGetUcadBrandingResourceInstance();


#ifdef _ZSOFT_WINDOWS_
typedef struct tagChildFrmSettings {

    UcColorSettings m_ColorSettings;
    bool m_bShowLayoutBar;
    bool m_bShowScrollBar;
    CDialogBar *m_pDialogBar;
    bool m_bIsBedit;
} UcChildFrmSettings;

BOOL ucedGetChildFrameSettings(UcChildFrmSettings* pChildFrmSettings,
    CMDIChildWnd *pWnd);
BOOL ucedSetChildFrameSettings(UcChildFrmSettings* pChildFrmSettings,
	CMDIChildWnd *pWnd);
#endif

#ifdef _ZSOFT_WINDOWS_
#ifdef _ZRX_CUSTOM_DRAG_N_DROP_

BOOL ucedRegisterCustomDropTarget(IDropTarget* pItarget);
BOOL ucedStartOverrideDropTarget(COleDropTarget* pTarget);

BOOL ucedRevokeCustomDropTarget();
BOOL ucedEndOverrideDropTarget(COleDropTarget* pTarget);

BOOL ucedAddDropTarget(COleDropTarget* pTarget);

BOOL ucedRemoveDropTarget(COleDropTarget* pTarget);

#endif 
#endif

#ifdef _ZSOFT_WINDOWS_
UcDbDatabase* UcApGetDatabase(CView *pView);
#endif

const CString& ucedGetRegistryCompany();

BOOL ucedRegisterExtendedTab(LPCTSTR szAppName, LPCTSTR szDialogName);

HMENU ucedGetMenu(LPCTSTR pszAlias);

BOOL ucedIsInputPending ();

#ifdef _ZSOFT_WINDOWS_
BOOL ucedSetIUnknownForCurrentCommand(const LPUNKNOWN);
BOOL ucedGetIUnknownForCurrentCommand(LPUNKNOWN &pUnk);
#endif

UcApStatusBar* ucedGetApplicationStatusBar();

BOOL ucedShowDrawingStatusBars(BOOL bShow = TRUE);

BOOL ucedDrawingStatusBarsVisible();

#ifdef _ZSOFT_WINDOWS_
BOOL ucedRegisterStatusBarMenuItem(UcStatusBarMenuItem* pItem,
                                   UcStatusBarMenuItem::UcStatusBarType nType);
BOOL ucedUnregisterStatusBarMenuItem(UcStatusBarMenuItem* pItem,
                                     UcStatusBarMenuItem::UcStatusBarType nType);
BOOL ucedSetStatusBarPaneID(UcPane* pPane,
                            UcStatusBarMenuItem::UcStatusBarType nType,
							int nID);
#endif



bool ucedHatchPalletteDialog(const ZTCHAR* pchCurrentPattern, bool bIsShowCustomPattern, ZTCHAR*& prefchNewSelectedPattern);

int UDCHatchGetRegistryHPFileName(CString& strHPFileName);
int UDCHatchWriteRegistryHPFileName(CString strHPFileName);

#pragma pack (pop)
#endif 
